package com.cc.tojsonscheam.ds;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Map;

/**
 * @author cc
 * @date 2022/8/30
 */
public interface GeneratorJsonMapper {

    @Select("SELECT COLUMN_NAME as name, COLUMN_TYPE as type, COLUMN_COMMENT as comment FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_SCHEMA = #{dsName} AND table_name = #{tableName}")
    List<Map<String,Object>> selectTableInfo(@Param("dsName")String dsName,@Param("tableName")String tableName);
}
